<template>
	<view class="empty-content">
		<image class="empty-content-image" :src="src" mode="widthFix" v-if="!isReceipt"></image>
		<view v-if="!isReceipt">亲爱的</view>
		<view v-if="!isReceipt">当前暂无数据，请稍后再来。</view>
		<view class="receipt-box" v-if="isReceipt">
			<view class="jia" @click="action(1)">
				<text class="icon-font add-icon" >&#xe606;</text>
			</view>
			<view class="receip-txt">选择开单的产品</view>
		</view>
	</view>
</template>

<script>
	export default {
			   //是否是开单
		props:["isReceipt"],
		data(){
			return{
				src:""
			}
		},
		methods:
		{
			action(act)
			{
				this.$emit("emptyAct",act);
			}
		}
	}
</script>

<style lang="scss">
	.empty-content {
		color: #656565;
		font-size: 24upx;
		text-align: center;
		&-image {
			margin-top: 120upx;
			margin-bottom: 30upx;
			width: 130upx;
			height: 170upx;
		}
		view:last-child{
			margin-top: 15upx;
		}
		.receipt-box
		{
			padding-top: 20px;
			width: 100%;
			// text-align: center;
			height: calc(100% - 110px);
			display: flex;
			justify-content: center;
			align-items: center;
			.jia
			{
				width: 50px;
				height: 50px;
				border-radius: 50%;
				background-color: #EEE;
				cursor: pointer;
				.add-icon
				{
					width: 100%;
					height: 100%;
					font-size: 24px;
				}
			}
			.receip-txt
			{
				padding-left: 10px;
			}
		}
	}
</style>
